﻿using Star_Helper;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class Default2 : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            string sx = Request.Form["name"];
            if (sx != null && sx != "undefined")
            {
                switch (sx)
                {
                    case "mingxi":
                        Response.Write(new DoDom().creaM1a());
                        break;
                    case "cunru":
                        Response.Write(new DoDom().creaM1b());
                        break;
                    case "zhichu":
                        Response.Write(new DoDom().creaM1c()); 
                        break;
                    case "leibie":
                        Response.Write(new DoDom().creadTable(Request.Form["name2"]));
                        break;
                    case "shangpin":
                        Response.Write(new DoDom().creaFe2tag(Request.Form["name2"]));
                        break;
                    case "selelei":
                        Response.Write(new DoDom().creaOp2(Request.Form["name2"]));
                        break;
                    case "ruku"://先存再返回数据
                        new DoDB().caozuoR(Request.Form["shangpin"],int.Parse(Request.Form["inp"]));
                        Response.Write(new DoDom().creaJiTable(1));
                        break;
                    case "chuku":
                        new DoDB().caozuoC(Request.Form["shangpin"], int.Parse(Request.Form["inp"]));
                        Response.Write(new DoDom().creaJiTable(2));
                        break;
                    default:

                        break;
                }
                Response.End();
            }

        }
    }
 
    public void postLog(string sx)
    {
        dataFunc.writeDoLogs("post详情", sx, "postLog",1);
    }

}